package com.t213.smbms.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;

import com.t213.smbms.entity.Provider;
import com.t213.smbms.mapper.ProviderMapper;
import com.t213.smbms.service.ProviderService;

@Transactional
@Service("updateService")
public class ProviderServiceimpl implements ProviderService{
	@Autowired
	private ProviderMapper providerMapper;
	
	public void setProviderMapper(ProviderMapper providerMapper) {
		this.providerMapper = providerMapper;
	}


	@Override
	public List<Provider> findProvider() {
		// TODO Auto-generated method stub
		return providerMapper.find();
	}


	@Override
	public List<Provider> findlistpro(String code, String proName) {
		return providerMapper.findlist(code, proName);
	}


	@Override
	public List<Provider> onefind() {
		return providerMapper.findone();
	}


	@Override
	public Provider seleone(int id) {
		return providerMapper.seleget(id);
	}


	@Override
	public int dele(int id) {
		return providerMapper.delete(id);
	}


	@Override
	public int up(Provider provider) {
		return providerMapper.update(provider);
	}



}
